"""
@Date: 2022/4/7
@Author: pyn
"""

import pandas as pd


def func():
    global b
    a = 99
    b = 101

    return True


if __name__ == '__main__':
    df = pd.read_excel('./rawdata/srd.xlsx')
    df['Unnamed: 0'] = df['Unnamed: 0'].str[0:19]
    df['date'] = df.apply(lambda x: x['Unnamed: 0'][0:10], axis=1)
    df['date'] = df['date'].str.replace('-', '/')

    df['time'] = df.apply(lambda x: x['Unnamed: 0'][-8:], axis=1)
    df['date'] = df['date'].astype('datetime64').dt.strftime('%Y%m%d').astype('int64')
    df['time'] = (df['date'] - 19900000) * 10000 + df['time'].str.replace(':', '').str[:-2].astype('int')
    df['_time_'] = df['date'] * 10000 + df['time']
